home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / pophel / pophelp2.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1995-09-06  |  4.1 KB  |  132 lines

  1. VERSION 2.00
  2. Begin Form Form1 
  3.    Caption         =   "Poplup Help"
  4.    ClientHeight    =   2670
  5.    ClientLeft      =   1095
  6.    ClientTop       =   1485
  7.    ClientWidth     =   5085
  8.    Height          =   3075
  9.    Left            =   1035
  10.    LinkTopic       =   "Form1"
  11.    ScaleHeight     =   2670
  12.    ScaleWidth      =   5085
  13.    Top             =   1140
  14.    Width           =   5205
  15.    Begin PictureBox Picture1 
  16.       Align           =   2  'Align Bottom
  17.       BackColor       =   &H00C0C0C0&
  18.       Height          =   495
  19.       Left            =   0
  20.       ScaleHeight     =   465
  21.       ScaleWidth      =   5055
  22.       TabIndex        =   1
  23.       Top             =   2175
  24.       Width           =   5085
  25.       Begin Timer Timer2 
  26.          Enabled         =   0   'False
  27.          Interval        =   50
  28.          Left            =   6825
  29.          Top             =   30
  30.       End
  31.       Begin Timer Timer1 
  32.          Enabled         =   0   'False
  33.          Interval        =   850
  34.          Left            =   6300
  35.          Top             =   1000
  36.       End
  37.    End
  38.    Begin PictureBox picToolbar 
  39.       Align           =   1  'Align Top
  40.       BackColor       =   &H00C0C0C0&
  41.       Height          =   510
  42.       Left            =   0
  43.       ScaleHeight     =   480
  44.       ScaleWidth      =   5055
  45.       TabIndex        =   0
  46.       Top             =   0
  47.       Width           =   5085
  48.       Begin PictureBox pshToolBtn 
  49.          Height          =   345
  50.          Index           =   0
  51.          Left            =   90
  52.          ScaleHeight     =   315
  53.          ScaleWidth      =   375
  54.          TabIndex        =   3
  55.          Top             =   60
  56.          Width           =   405
  57.       End
  58.       Begin PictureBox PicClip1 
  59.          Height          =   480
  60.          Left            =   0
  61.          Picture         =   POPHELP2.FRX:0000
  62.          ScaleHeight     =   450
  63.          ScaleWidth      =   1170
  64.          TabIndex        =   4
  65.          Top             =   0
  66.          Width           =   1200
  67.       End
  68.    End
  69.    Begin Label labHelpMessage 
  70.       AutoSize        =   -1  'True
  71.       BackColor       =   &H0080FFFF&
  72.       BorderStyle     =   1  'Fixed Single
  73.       Caption         =   "labHelpMessage"
  74.       Height          =   225
  75.       Left            =   2280
  76.       TabIndex        =   2
  77.       Top             =   720
  78.       Visible         =   0   'False
  79.       Width           =   1440
  80.    End
  81. Option Explicit
  82.    DefInt A-Z
  83.    Dim gNumBtns
  84.    Dim CurrentButton
  85. Sub Form_Load ()
  86.    Dim I As Integer
  87.    Dim gCurrBtn
  88.    gNumBtns = picClip1.Cols
  89.    gCurrBtn = -1
  90. '--LOAD TOOLBAR BUTTONS
  91.    For I = 0 To gNumBtns - 1
  92.       If I > 0 Then
  93.          Load pshToolBtn(I)
  94.          pshToolBtn(I).Left = pshToolBtn(I - 1).Left + pshToolBtn(I - 1).Width - 1
  95.          pshToolBtn(I).Visible = True
  96.       End If
  97.       pshToolBtn(I).PictureUp = picClip1.GraphicCell(I)
  98.    Next I
  99. '--USE TAG TO HOLD HELP MESSAGE
  100.    pshToolBtn(0).Tag = "Clear workspace"
  101.    pshToolBtn(1).Tag = "Open previous workspace"
  102.    pshToolBtn(2).Tag = "Save current workspace"
  103.    pshToolBtn(3).Tag = "Calculate"
  104.    pshToolBtn(4).Tag = "Cut to Clipboard"
  105.    pshToolBtn(5).Tag = "Insert Excel Object"
  106.    pshToolBtn(6).Tag = "Exit demo program"
  107. End Sub
  108. Sub picToolbar_MouseMove (Button As Integer, Shift As Integer, X As Single, Y As Single)
  109.    labHelpMessage.Visible = False
  110.    Timer1.Enabled = False
  111. End Sub
  112. Sub pshToolBtn_Click (Index As Integer, Value As Integer)
  113. '--POP BUTTON BACK
  114.    pshToolBtn(Index).Value = False
  115. '--THE EXIT BUTTON REALLY WORKS
  116.    If Index = gNumBtns - 1 Then
  117.       End
  118.    End If
  119. End Sub
  120. Sub pshToolBtn_MouseMove (Index As Integer, Button As Integer, Shift As Integer, X As Single, Y As Single)
  121.    CurrentButton = Index
  122.    labHelpMessage.Visible = False
  123.    Timer1.Enabled = False
  124.    Timer1.Enabled = True
  125. End Sub
  126. Sub Timer1_Timer ()
  127.    labHelpMessage = pshToolBtn(CurrentButton).Tag
  128.    labHelpMessage.Left = pshToolBtn(CurrentButton).Left
  129.    labHelpMessage.Visible = True
  130.    Timer1.Enabled = False
  131. End Sub
  132.